cssvalue: At cycle detection to color resolving
authorBenjamin Otte <otte@redhat.com>
Thu, 28 Mar 2013 22:13:43 +0000 (23:13 +0100)
committerBenjamin Otte <otte@redhat.com>
Thu, 28 Mar 2013 22:18:59 +0000 (23:18 +0100)
commitcbee3901486781370f50ee02f49bdbd463f3eaa3
tree1fa0753468338560bed086dcfd77b69535c22ca8
parentc25d8e3aea900f8ae2abd2907a5b8a2e89e7ee9e
cssvalue: At cycle detection to color resolving

The following CSS would infloop:

@define-color self @self

as it would infinitely lookup the color named "self" and try to resolve
it. This patch adds detection of such cycles to the resolve function by
keeping a list of currently resolving colors in the cycle_list variable.
gtk/deprecated/gtkgradient.c
gtk/deprecated/gtksymboliccolor.c
gtk/gtkcsscolorvalue.c
gtk/gtkcsscolorvalueprivate.h
gtk/gtkcssstylefuncs.c
gtk/gtkstylecontext.c